<template>
	<view class="content font_family">
		<view class="item" v-for="(item,index) in tz_list" :key="index">
			<view class="title f_j">
				<image src="../../static/public/xt_tz.png" mode=""></image>
				<view class="">
					系统通知：订单{{item.node=='fh'?'发货':'退款'}}
				</view>
			</view>
			<spbox :list='item.detail'></spbox>
			<view class="tz_msg">
				<view class="msg_item f">
					<view class="left">
						{{item.node=='fh'?'发货':'退款'}}时间：
					</view>
					<view class="right">
						{{item.createtime}}
					</view>
				</view>
				<view class="msg_item f">
					<view class="left">
						订单编号：
					</view>
					<view class="right">
						{{item.order_no}}
					</view>
				</view>
				<view class="msg_item f">
					<view class="left">
						{{item.node=='fh'?'订单':'退款'}}金额：
					</view>
					<view class="right">
						￥{{item.order_amount_total}}
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	import { mapState } from 'vuex'
	export default {
		computed: {
			...mapState(['user_info', 'tz_list'])
		},
		data() {
			return {

			}
		},
		onLoad() {
			this.get_list()
		},
		methods: {
			//获取通知列表
			get_list() {
				var send_msg = {
					c: 'Message',
					a: 'systemNotice',
					data: {
						user_id: this.user_info.id
					}
				}
				this.$me_scoket.send(send_msg)
			}
		}
	}
</script>

<style lang="scss" scoped>
	.content {
		padding: 30rpx;

		.item {
			margin-bottom: 30rpx;
			padding: 30rpx;
			background: #FFFFFF;
			border-radius: 8rpx 8rpx 8rpx 8rpx;

			.title {
				border-bottom: 2rpx solid #E4E7ED;
				font-weight: 400;
				font-size: 28rpx;
				color: #3D3D3D;
				padding-bottom: 15rpx;
				margin-bottom: 20rpx;

				image {
					width: 64rpx;
					height: 64rpx;
					margin-right: 20rpx;
				}
			}

			.tz_msg {
				.msg_item {
					padding: 10rpx 0rpx;

					.left {
						font-weight: 400;
						font-size: 28rpx;
						color: #666666;
					}

					.right {
						font-weight: 400;
						font-size: 28rpx;
						color: #232323;
					}
				}
			}
		}
	}
</style>